package com.sad.jetpack.v1.datamodel.api.extension.client.socket.ipc;

import java.io.File;

public interface IPCChatFileSessionListener {

    void onReadyToStart(IPCChatSessionManager sessionManager, IFileDownloader downloader,IFileUploader uploader);

    void onChatFile(IPCChatSessionManager sessionManager, IFileDownloader downloader,IFileUploader uploader,String receivedFileName);

    void onReceivedFile(IPCChatSessionManager sessionManager,File f);

    void onSentFile(IPCChatSessionManager sessionManager,File f);

    void onDownloadFileProgress(IPCChatSessionManager sessionManager,String fn,int curr,int total);

    void onUploadFileProgress(IPCChatSessionManager sessionManager,String fn,int curr,int total);

    interface IFileDownloader {
        void doDownLoad(int cacheSize,String fp) throws Exception;//完整路径
    }

    interface IFileUploader{
        void doUpLoad(int cacheSize,String fp) throws Exception;//完整路径
    }

}
